package com.bianmaba.dc.configure;

import com.bianmaba.dc.supports.services.AbstractCollectionService;
import com.bianmaba.dc.supports.services.DefaultCollectionService;
import lombok.extern.log4j.Log4j2;
import org.springframework.boot.autoconfigure.condition.ConditionalOnMissingBean;
import org.springframework.context.annotation.Bean;

@Log4j2
public class CollectionSupportsAutoConfigure {
    public CollectionSupportsAutoConfigure() {
        log.info("CollectionSupportsAutoConfigure inited");
    }

    @Bean
    @ConditionalOnMissingBean(AbstractCollectionService.class)
    public AbstractCollectionService defaultCollectionService() {
        return new DefaultCollectionService();
    }
}
